package sicnu.cs.ich.ich.ranking.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import sicnu.cs.ich.api.domain.dto.*;
import sicnu.cs.ich.api.domain.entity.Ich;
import sicnu.cs.ich.api.domain.entity.IchProvince;

import java.util.ArrayList;
import java.util.List;

/**
 * @author sy
 */
@Mapper
public interface IchMapper extends BaseMapper<Ich> {

    /**
     *
     */
    void batchUpdateIchHot(@Param("list") List<IchHotDTO> ichRankRecordList);

    /**
     * 增加助力值
     *
     * @param ichId 非遗id
     * @param value 助力值
     */
    void updateIchHot(Integer ichId, Integer value);

    /**
     * 获取助力值
     *
     * @param ichId
     * @return
     */
    Integer selectIchLikingById(Integer ichId);

    List<IchHotDTO> selectProvinceIchHotDTO(String province, int num);
}